package cn.felord.collection.queue;

import java.util.ArrayDeque;
import java.util.Deque;
import java.util.Iterator;

/**
 * @author Dax
 * @since 17:38  2018/7/1
 */
public class MyQueue {
    public static void main(String[] args) {
        Deque<String> deque=new ArrayDeque<>();
        System.out.println(deque.size());
            deque.add("aa");
            deque.add("bb");
            deque.add("cc");
            deque.add("dd");
            deque.add("ee");
            deque.add("ff");
            Iterator<String> iterable= deque.descendingIterator();
         while (iterable.hasNext()){
             System.out.println(iterable.next());
         }
    }
}
